/* eslint-disable */
//  异步问题会导致AdCount 数据库出现奇怪的问题
var http = require("http")
let AdCount = require("../dbServer/dbSync").AdCount
new http.Server(
	async (request, response) => {
		let oid = 11
		let adClick = (Math.random() * 500) | 0
		console.log(adClick)
		console.log(await AdCount.upsert({
			oid,
			date: Date.now(),
			adClick
		}, {fields: ["adClick"]})
		)
		response.end("12323")
	}
).listen(3000)